/*
* // +-------------------------------------------------------------------------------------------------
* // |                 有你就好 [ 有节骨乃坚，无心品自端 ]     <http://encoding.wang>
* // +-------------------------------------------------------------------------------------------------
* // |                             独在异乡为异客         每逢佳节倍思亲
* // +-------------------------------------------------------------------------------------------------
* // |                 联系:   <707069100@qq.com>      <http://weibo.com/513778937>
* // +-------------------------------------------------------------------------------------------------
*/

// -----------------------------------------------------------------------------------------------------
// +----------------------------------------------------------------------------------------------------
// |                   ErYang出品 属于小极品          共同学习    共同进步
// +----------------------------------------------------------------------------------------------------
// -----------------------------------------------------------------------------------------------------


package wang.encoding.mroot.service.cms


import wang.encoding.mroot.model.entity.cms.Category
import wang.encoding.mroot.common.service.BaseService

import java.math.BigInteger

/**
 * 后台 文章分类 Service 接口
 *
 * @author ErYang
 */
interface CategoryService : BaseService<Category> {


    /**
     * 初始化新增 Category 对象
     *
     * @param category Category
     * @return Category
     */
    fun initSaveCategory(category: Category): Category

    // -------------------------------------------------------------------------------------------------

    /**
     * 初始化修改 Category 对象
     *
     * @param category Category
     * @return Category
     */
    fun initEditCategory(category: Category): Category

    // -------------------------------------------------------------------------------------------------

    /**
     * Hibernate Validation 验证
     */
    fun validationCategory(category: Category): String?

    // -------------------------------------------------------------------------------------------------

    /**
     * 根据标识查询 Category
     *
     * @param name 标识
     * @return Category
     */
    fun getByName(name: String): Category?

    // -------------------------------------------------------------------------------------------------

    /**
     * 根据名称查询 Category
     *
     * @param title 名称
     * @return Category
     */
    fun getByTitle(title: String): Category?

    // -------------------------------------------------------------------------------------------------

    /**
     * 新增 文章分类
     *
     * @param category Category
     * @return ID  BigInteger
     */
    fun saveBackId(category: Category): BigInteger?

    // -------------------------------------------------------------------------------------------------

    /**
     * 更新 文章分类
     *
     * @param category Category
     * @return ID  BigInteger
     */
    fun updateBackId(category: Category): BigInteger?

    // -------------------------------------------------------------------------------------------------

    /**
     * 删除 文章分类 (更新状态)
     *
     * @param id BigInteger
     * @return ID  BigInteger
     */
    fun removeBackId(id: BigInteger): BigInteger?

    // -------------------------------------------------------------------------------------------------

    /**
     * 恢复 文章分类 (更新状态)
     *
     * @param id BigInteger
     * @return ID  BigInteger
     */
    fun recoverBackId(id: BigInteger): BigInteger?

    // -------------------------------------------------------------------------------------------------

    /**
     * 得到 类型小于 3 文章分类集合
     *
     * @return  List<Category>
     */
    fun listTypeLt3(): List<Category>?

    // -------------------------------------------------------------------------------------------------

}

// -----------------------------------------------------------------------------------------------------

// End CategoryService interface

/* End of file CategoryService.kt */
/* Location: ./src/main/kotlin/wang/encoding/mroot/service/cms/Category.kt */

// -----------------------------------------------------------------------------------------------------
// +----------------------------------------------------------------------------------------------------
// |                           ErYang出品 属于小极品  O(∩_∩)O~~   共同学习    共同进步
// +----------------------------------------------------------------------------------------------------
// -----------------------------------------------------------------------------------------------------
// -----------------------------------------------------------------------------------------------------
